Q: Which of the following is not a JavaScript framework?
Solution: Dojo Toolkit is an open source modular JavaScript library (or more specifically JavaScript toolkit) designed to ease the rapid development of cross-platform, JavaScript/Ajax-based applications and web sites. Rico was an open-source JavaScript library for developing rich internet applications with Ajax.
Q: What is the purpose of the Math method toSource()?
Solution: The method Math.toSource() returns the string “Math”. But this method does not work with many browsers like IE. The toSource() method returns a string representing the source code of the object.
Q: What will be the output of the following JavaScript code? var o = new F(); o.constructor === F
Solution: ’===’ sign is used for comparing the type of values. The result is true if the constructor property specifies the class.
Q: How many static methods does a Date object have?
Solution: Date objects are created with the new Date() constructor. The Date object defines two static methods namely Date.parse() and Date.UTC().
Q: Which of the following are static methods in JavaScript?
Solution: Date objects are created with the new Date() constructor. Date.parse() parses a string representation of a date and time and returns the internal millisecond representation of that date. Date.UTC() Returns the millisecond representation of the specified UTC date and time.
Q: What will be the work of the getAvg in the following JavaScript function?Q: Which of the following is not an object?A. ElementB. LocationC. PositionD. WindowSolution: The window object represents an open window in a browser. There is no object called Position.Q: What is the code snippet to change the class and let the stylesheet specify the details?A. timestamp.className = “highlight”;B. timestamp.className = “change”;C. timestamp.className = “specify”;D. timestamp.className = “move”;Solution: “typename” is a keyword in the C++ programming language used when writing templates. The above code snippet changes the class and lets the stylesheet specify the details.
You Have Score    | /10 |